package com.linsen.oss.feign;

import com.linsen.core.common.constant.ProviderConstant;
import com.linsen.core.common.util.QREncode;
import com.linsen.core.common.util.Result;
import com.linsen.oss.provider.feign.IOssFeignClient;
import com.linsen.oss.service.FileUploadService;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * @Description:
 * @ProjectName: erp
 * @Package: com.linsen.oss.feign
 * @ClassName: OssFeignClient
 * @Author: zhaoyong
 * @Email: zy765203718@gmail.com
 * @Date: 2023/8/8 15:12
 * @Version: 1.0
 */
@Slf4j
@RestController
@RequiredArgsConstructor
public class OssFeignClient implements IOssFeignClient {

    private final FileUploadService fileUploadService;

    @Override
    @GetMapping(ProviderConstant.PROVIDER_CREATE_QRCODE)
    public Result createQrCode(String content) {
        return Result.data(fileUploadService.createQrCode(content));
    }
}
